package com.itheima.reggie.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.itheima.reggie.entity.Orders;
import com.itheima.reggie.entity.R;

/**
 * <b><code>IOrdersService</code></b>
 * <p/>
 * Description
 * <p/>
 * <b>Creation Time:</b> 29/06/2024 20:47.
 *
 * @author yanjr
 * @since reggie_take_out
 */
public interface IOrdersService extends IService<Orders> {
    /**
     * 用户下单
     * @param orders 订单信息
     * @return 是否成功
     */
    R<String> submit(Orders orders);

    /**
     * 查看订单
     * @param page 当前页
     * @param pageSize 每页显示条数
     * @return 分页信息
     */
    R<Page<Orders>> userPage(int page, int pageSize);
}
